<?php
$form = $this->beginWidget('CActiveForm', array(
    'id' => 'form-kehoachdauthau',
    'enableClientValidation' => true,
    'clientOptions' => array(
        'validateOnSubmit' => true,
    ),
        ));
?>
<div class="form-group">
    <label class="control-label">Tên kế hoạch</label>
    <?php echo $form->textField($model, 'tenKeHoach', array('class' => 'form-control')) ?>
    <?php echo $form->error($model, 'tenKeHoach', array('class' => 'error-message')); ?>
</div>
<div class="form-group">
    <label class="control-label">Quyết định phê duyệt đấu thầu</label>
    <?php echo $form->textArea($model, 'quyetDinh', array('class' => 'form-control')) ?>
    <?php echo $form->error($model, 'quyetDinh', array('class' => 'error-message')); ?>
</div>
<div class="form-group">
    <label class="control-label">Chủ đầu tư</label>
    <?php echo $form->textField($model, 'chuDauTu', array('class' => 'form-control')) ?>
    <?php echo $form->error($model, 'chuDauTu', array('class' => 'error-message')); ?>
</div>
<div class="form-group">
    <label class="control-label">Tổng mức đầu tư</label>
    <?php echo $form->textField($model, 'tongMucDauTu', array('class' => 'form-control')) ?>
    <?php echo $form->error($model, 'tongMucDauTu', array('class' => 'error-message')); ?>
</div>
<div class="form-group">
    <label class="control-label">Danh sách dự án</label>
    <?php echo $form->textArea($model, 'danhSachDuAn', array('class' => 'ckeditor form-control')) ?>
    <?php echo $form->error($model, 'danhSachDuAn', array('class' => 'error-message')); ?>
</div>
<div class="form-group">
    <label class="control-label">Ngày xuất bản</label>
    <?php
    Yii::import('application.extensions.CJuiDateTimePicker.CJuiDateTimePicker');
    $this->widget('CJuiDateTimePicker', array(
        'model' => $model,
        'attribute' => 'ngayXuatBan',
        'language' => '',
        'mode' => 'date',
        'htmlOptions' => array(
            'class' => 'form-control'
        ),
            )
    );
    ?>
    <?php echo $form->error($model, 'ngayXuatBan', array('class' => 'error-message')); ?>
</div>
<div class="form-group">
    <label class="control-label">Số báo đăng</label>
    <?php echo $form->textField($model, 'soBaoDang', array('class' => 'form-control')) ?>
    <?php echo $form->error($model, 'soBaoDang', array('class' => 'error-message')); ?>
</div>
<div class="form-group">
    <label class="control-label">Tình trạng thông tin</label>
    <?php echo $form->textArea($model, 'tinhTrang', array('class' => 'form-control')) ?>
    <?php echo $form->error($model, 'tinhTrang', array('class' => 'error-message')); ?>
</div>
<div class="form-group">
    <label class="control-label">Mã thông tin</label>
    <?php echo $form->textField($model, 'maThongTin', array('class' => 'form-control')) ?>
    <?php echo $form->error($model, 'maThongTin', array('class' => 'error-message')); ?>
</div>
<div class="form-actions">
    <button onclick="CKupdate()" type="submit" class="btn btn-primary">Lưu</button>
    <a href="<?php echo $this->createUrl('user/listnews') ?>" class="btn btn-default">Quay lại danh sách</a>
</div>
<?php $this->endWidget(); ?>
<script type="text/javascript">
function CKupdate() {
    for (instance in CKEDITOR.instances)
        CKEDITOR.instances[instance].updateElement();
}
</script>